# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=interlace
pkgver=356.b9eb99f
pkgrel=1
pkgdesc='Easily turn single threaded command line applications into a fast, multi-threaded application with CIDR and glob support.'
groups=('blackarch' 'blackarch-networking')
arch=('any')
url='https://github.com/codingo/Interlace/releases'
license=('GPL3')
depends=('python' 'python-colorclass' 'python-netaddr' 'python-tqdm')
makedepends=('git' 'python-setuptools')
source=("$pkgname::git+https://github.com/codingo/Interlace.git")
sha512sums=('SKIP')

pkgver() {
  cd $pkgname

  echo $(git rev-list --count HEAD).$(git rev-parse --short HEAD)
}

prepare() {
  cd $pkgname

  sed -i 's/==.*//g' requirements.txt
}

build() {
  cd $pkgname

  python setup.py build
}

package() {
  cd $pkgname

  python setup.py install --prefix=/usr --root="$pkgdir" -O1 --skip-build
}

